<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>
<body>
  <script>
    // 严格模式

    function sum () {
      'use strict'
      console.log(arguments) // 类数组对象
      const args = Array.from(arguments) // 转换为数组
      return args.reduce((acc, curr) => acc + curr, 0)
    }

  </script>
</body>
</html>